/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * jFTiposClientes.java
 *
 * Created on 02/12/2012, 21:25:53
 */

package ecommercial;

import ecommercial.Classes.ClassConecta;
import ecommercial.Classes.ColorRenderer;
import ecommercial.Classes.ComboItem;
import ecommercial.Classes.Funcoes;
import ecommercial.Classes.TabelaPrecos;
import ecommercial.Classes.TiposClientes;
import java.awt.Color;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.text.ParseException;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.JColorChooser;
import javax.swing.JOptionPane;
import javax.swing.table.DefaultTableModel;

/**
 *
 * @author Luciano Carrafa Benfica
 */
public class jFTiposClientes extends javax.swing.JFrame {

    /** Creates new form jFTiposClientes */
    public jFTiposClientes() {
        initComponents();
    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jToolBar1 = new javax.swing.JToolBar();
        buscarjButton = new javax.swing.JButton();
        novojButton = new javax.swing.JButton();
        editarjButton = new javax.swing.JButton();
        salvarjButton = new javax.swing.JButton();
        salvarMaisjButton = new javax.swing.JButton();
        jSeparator1 = new javax.swing.JToolBar.Separator();
        alterarjButton = new javax.swing.JButton();
        excluirjButton = new javax.swing.JButton();
        jSeparator2 = new javax.swing.JToolBar.Separator();
        sairjButton = new javax.swing.JButton();
        jPanel1 = new javax.swing.JPanel();
        jTabbedPane1 = new javax.swing.JTabbedPane();
        jPanel2 = new javax.swing.JPanel();
        jLabel1 = new javax.swing.JLabel();
        tipoTabelaPrecojComboBox = new javax.swing.JComboBox();
        cadastraTipoTabela = new javax.swing.JButton();
        atualizaTabelaPrecojButton = new javax.swing.JButton();
        tipojTextField = new javax.swing.JTextField();
        jLabel2 = new javax.swing.JLabel();
        urgenciajComboBox = new javax.swing.JComboBox();
        jLabel3 = new javax.swing.JLabel();
        jLabel4 = new javax.swing.JLabel();
        bloquearVendaInadimplenmtejComboBox = new javax.swing.JComboBox();
        tempoMedioAtendimentojTextField = new javax.swing.JTextField();
        jLabel5 = new javax.swing.JLabel();
        corjTextField = new javax.swing.JTextField();
        jLabel6 = new javax.swing.JLabel();
        paletaCoresjButton = new javax.swing.JButton();
        painelDeCorjPanel = new javax.swing.JPanel();
        jPanel4 = new javax.swing.JPanel();
        jScrollPane1 = new javax.swing.JScrollPane();
        descricaojTextArea = new javax.swing.JTextArea();
        jPanel5 = new javax.swing.JPanel();
        jScrollPane2 = new javax.swing.JScrollPane();
        gradeTipoClientesjTable = new javax.swing.JTable();

        setDefaultCloseOperation(javax.swing.WindowConstants.DO_NOTHING_ON_CLOSE);
        setName("Form"); // NOI18N
        setResizable(false);
        addWindowListener(new java.awt.event.WindowAdapter() {
            public void windowOpened(java.awt.event.WindowEvent evt) {
                formWindowOpened(evt);
            }
        });

        org.jdesktop.application.ResourceMap resourceMap = org.jdesktop.application.Application.getInstance(ecommercial.EcommercialApp.class).getContext().getResourceMap(jFTiposClientes.class);
        jToolBar1.setBackground(resourceMap.getColor("jToolBar1.background")); // NOI18N
        jToolBar1.setFloatable(false);
        jToolBar1.setRollover(true);
        jToolBar1.setName("jToolBar1"); // NOI18N

        buscarjButton.setBackground(resourceMap.getColor("buscarjButton.background")); // NOI18N
        buscarjButton.setIcon(resourceMap.getIcon("buscarjButton.icon")); // NOI18N
        buscarjButton.setText(resourceMap.getString("buscarjButton.text")); // NOI18N
        buscarjButton.setFocusable(false);
        buscarjButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        buscarjButton.setName("buscarjButton"); // NOI18N
        buscarjButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        buscarjButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                buscarjButtonActionPerformed(evt);
            }
        });
        jToolBar1.add(buscarjButton);

        novojButton.setBackground(resourceMap.getColor("novojButton.background")); // NOI18N
        novojButton.setIcon(resourceMap.getIcon("novojButton.icon")); // NOI18N
        novojButton.setText(resourceMap.getString("novojButton.text")); // NOI18N
        novojButton.setFocusable(false);
        novojButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        novojButton.setName("novojButton"); // NOI18N
        novojButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        novojButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                novojButtonActionPerformed(evt);
            }
        });
        jToolBar1.add(novojButton);

        editarjButton.setBackground(resourceMap.getColor("editarjButton.background")); // NOI18N
        editarjButton.setIcon(resourceMap.getIcon("editarjButton.icon")); // NOI18N
        editarjButton.setText(resourceMap.getString("editarjButton.text")); // NOI18N
        editarjButton.setFocusable(false);
        editarjButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        editarjButton.setName("editarjButton"); // NOI18N
        editarjButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        editarjButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                editarjButtonActionPerformed(evt);
            }
        });
        jToolBar1.add(editarjButton);

        salvarjButton.setBackground(resourceMap.getColor("salvarjButton.background")); // NOI18N
        salvarjButton.setIcon(resourceMap.getIcon("salvarjButton.icon")); // NOI18N
        salvarjButton.setText(resourceMap.getString("salvarjButton.text")); // NOI18N
        salvarjButton.setFocusable(false);
        salvarjButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        salvarjButton.setName("salvarjButton"); // NOI18N
        salvarjButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        salvarjButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                salvarjButtonActionPerformed(evt);
            }
        });
        jToolBar1.add(salvarjButton);

        salvarMaisjButton.setBackground(resourceMap.getColor("salvarMaisjButton.background")); // NOI18N
        salvarMaisjButton.setIcon(resourceMap.getIcon("salvarMaisjButton.icon")); // NOI18N
        salvarMaisjButton.setText(resourceMap.getString("salvarMaisjButton.text")); // NOI18N
        salvarMaisjButton.setFocusable(false);
        salvarMaisjButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        salvarMaisjButton.setName("salvarMaisjButton"); // NOI18N
        salvarMaisjButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        salvarMaisjButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                salvarMaisjButtonActionPerformed(evt);
            }
        });
        jToolBar1.add(salvarMaisjButton);

        jSeparator1.setName("jSeparator1"); // NOI18N
        jToolBar1.add(jSeparator1);

        alterarjButton.setBackground(resourceMap.getColor("alterarjButton.background")); // NOI18N
        alterarjButton.setIcon(resourceMap.getIcon("alterarjButton.icon")); // NOI18N
        alterarjButton.setText(resourceMap.getString("alterarjButton.text")); // NOI18N
        alterarjButton.setFocusable(false);
        alterarjButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        alterarjButton.setName("alterarjButton"); // NOI18N
        alterarjButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        alterarjButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                alterarjButtonActionPerformed(evt);
            }
        });
        jToolBar1.add(alterarjButton);

        excluirjButton.setBackground(resourceMap.getColor("excluirjButton.background")); // NOI18N
        excluirjButton.setIcon(resourceMap.getIcon("excluirjButton.icon")); // NOI18N
        excluirjButton.setText(resourceMap.getString("excluirjButton.text")); // NOI18N
        excluirjButton.setFocusable(false);
        excluirjButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        excluirjButton.setName("excluirjButton"); // NOI18N
        excluirjButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        excluirjButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                excluirjButtonActionPerformed(evt);
            }
        });
        jToolBar1.add(excluirjButton);

        jSeparator2.setName("jSeparator2"); // NOI18N
        jToolBar1.add(jSeparator2);

        sairjButton.setBackground(resourceMap.getColor("sairjButton.background")); // NOI18N
        sairjButton.setIcon(resourceMap.getIcon("sairjButton.icon")); // NOI18N
        sairjButton.setText(resourceMap.getString("sairjButton.text")); // NOI18N
        sairjButton.setFocusable(false);
        sairjButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        sairjButton.setName("sairjButton"); // NOI18N
        sairjButton.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        sairjButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                sairjButtonActionPerformed(evt);
            }
        });
        jToolBar1.add(sairjButton);

        jPanel1.setBackground(resourceMap.getColor("jPanel1.background")); // NOI18N
        jPanel1.setName("jPanel1"); // NOI18N

        jTabbedPane1.setName("jTabbedPane1"); // NOI18N

        jPanel2.setBackground(resourceMap.getColor("jPanel2.background")); // NOI18N
        jPanel2.setName("jPanel2"); // NOI18N

        jLabel1.setText(resourceMap.getString("jLabel1.text")); // NOI18N
        jLabel1.setName("jLabel1"); // NOI18N

        tipoTabelaPrecojComboBox.setName("tipoTabelaPrecojComboBox"); // NOI18N

        cadastraTipoTabela.setIcon(resourceMap.getIcon("cadastraTipoTabela.icon")); // NOI18N
        cadastraTipoTabela.setText(resourceMap.getString("cadastraTipoTabela.text")); // NOI18N
        cadastraTipoTabela.setToolTipText(resourceMap.getString("cadastraTipoTabela.toolTipText")); // NOI18N
        cadastraTipoTabela.setContentAreaFilled(false);
        cadastraTipoTabela.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        cadastraTipoTabela.setName("cadastraTipoTabela"); // NOI18N

        atualizaTabelaPrecojButton.setIcon(resourceMap.getIcon("atualizaTabelaPrecojButton.icon")); // NOI18N
        atualizaTabelaPrecojButton.setText(resourceMap.getString("atualizaTabelaPrecojButton.text")); // NOI18N
        atualizaTabelaPrecojButton.setContentAreaFilled(false);
        atualizaTabelaPrecojButton.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        atualizaTabelaPrecojButton.setName("atualizaTabelaPrecojButton"); // NOI18N
        atualizaTabelaPrecojButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                atualizaTabelaPrecojButtonActionPerformed(evt);
            }
        });

        tipojTextField.setText(resourceMap.getString("tipojTextField.text")); // NOI18N
        tipojTextField.setName("tipojTextField"); // NOI18N

        jLabel2.setText(resourceMap.getString("jLabel2.text")); // NOI18N
        jLabel2.setName("jLabel2"); // NOI18N

        urgenciajComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "0- NORMAL", "1- CRITICA", "2- ALTA", "3- MÉDIA", "4- BAIXA" }));
        urgenciajComboBox.setName("urgenciajComboBox"); // NOI18N

        jLabel3.setText(resourceMap.getString("jLabel3.text")); // NOI18N
        jLabel3.setName("jLabel3"); // NOI18N

        jLabel4.setText(resourceMap.getString("jLabel4.text")); // NOI18N
        jLabel4.setName("jLabel4"); // NOI18N

        bloquearVendaInadimplenmtejComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "NÃO", "SIM" }));
        bloquearVendaInadimplenmtejComboBox.setName("bloquearVendaInadimplenmtejComboBox"); // NOI18N

        tempoMedioAtendimentojTextField.setText(resourceMap.getString("tempoMedioAtendimentojTextField.text")); // NOI18N
        tempoMedioAtendimentojTextField.setToolTipText(resourceMap.getString("tempoMedioAtendimentojTextField.toolTipText")); // NOI18N
        tempoMedioAtendimentojTextField.setName("tempoMedioAtendimentojTextField"); // NOI18N

        jLabel5.setText(resourceMap.getString("jLabel5.text")); // NOI18N
        jLabel5.setName("jLabel5"); // NOI18N

        corjTextField.setEditable(false);
        corjTextField.setText(resourceMap.getString("corjTextField.text")); // NOI18N
        corjTextField.setFocusable(false);
        corjTextField.setName("corjTextField"); // NOI18N

        jLabel6.setText(resourceMap.getString("jLabel6.text")); // NOI18N
        jLabel6.setName("jLabel6"); // NOI18N

        paletaCoresjButton.setIcon(resourceMap.getIcon("paletaCoresjButton.icon")); // NOI18N
        paletaCoresjButton.setText(resourceMap.getString("paletaCoresjButton.text")); // NOI18N
        paletaCoresjButton.setContentAreaFilled(false);
        paletaCoresjButton.setCursor(new java.awt.Cursor(java.awt.Cursor.HAND_CURSOR));
        paletaCoresjButton.setName("paletaCoresjButton"); // NOI18N
        paletaCoresjButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                paletaCoresjButtonActionPerformed(evt);
            }
        });

        painelDeCorjPanel.setBorder(javax.swing.BorderFactory.createEtchedBorder());
        painelDeCorjPanel.setFocusable(false);
        painelDeCorjPanel.setName("painelDeCorjPanel"); // NOI18N

        javax.swing.GroupLayout painelDeCorjPanelLayout = new javax.swing.GroupLayout(painelDeCorjPanel);
        painelDeCorjPanel.setLayout(painelDeCorjPanelLayout);
        painelDeCorjPanelLayout.setHorizontalGroup(
            painelDeCorjPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 88, Short.MAX_VALUE)
        );
        painelDeCorjPanelLayout.setVerticalGroup(
            painelDeCorjPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 21, Short.MAX_VALUE)
        );

        javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
        jPanel2.setLayout(jPanel2Layout);
        jPanel2Layout.setHorizontalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel2Layout.createSequentialGroup()
                        .addComponent(tipoTabelaPrecojComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, 165, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(cadastraTipoTabela, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(6, 6, 6)
                        .addComponent(atualizaTabelaPrecojButton, javax.swing.GroupLayout.PREFERRED_SIZE, 15, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addComponent(jLabel1, javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, jPanel2Layout.createSequentialGroup()
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(bloquearVendaInadimplenmtejComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, 92, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel4))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel5)
                            .addComponent(tempoMedioAtendimentojTextField))))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel2Layout.createSequentialGroup()
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(corjTextField)
                            .addComponent(tipojTextField, javax.swing.GroupLayout.DEFAULT_SIZE, 158, Short.MAX_VALUE)
                            .addComponent(jLabel2))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(jLabel3)
                            .addComponent(urgenciajComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, 111, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addGroup(jPanel2Layout.createSequentialGroup()
                                .addComponent(paletaCoresjButton, javax.swing.GroupLayout.PREFERRED_SIZE, 17, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(painelDeCorjPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))))
                    .addComponent(jLabel6))
                .addContainerGap(114, Short.MAX_VALUE))
        );
        jPanel2Layout.setVerticalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel1)
                    .addComponent(jLabel2)
                    .addComponent(jLabel3))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(tipojTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(urgenciajComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addComponent(atualizaTabelaPrecojButton)
                    .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(tipoTabelaPrecojComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(cadastraTipoTabela)))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel4)
                    .addComponent(jLabel5)
                    .addComponent(jLabel6))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(painelDeCorjPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(paletaCoresjButton, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(bloquearVendaInadimplenmtejComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(tempoMedioAtendimentojTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(corjTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addGap(252, 252, 252))
        );

        jTabbedPane1.addTab(resourceMap.getString("jPanel2.TabConstraints.tabTitle"), jPanel2); // NOI18N

        jPanel4.setName("jPanel4"); // NOI18N

        jScrollPane1.setName("jScrollPane1"); // NOI18N

        descricaojTextArea.setColumns(20);
        descricaojTextArea.setRows(5);
        descricaojTextArea.setName("descricaojTextArea"); // NOI18N
        jScrollPane1.setViewportView(descricaojTextArea);

        javax.swing.GroupLayout jPanel4Layout = new javax.swing.GroupLayout(jPanel4);
        jPanel4.setLayout(jPanel4Layout);
        jPanel4Layout.setHorizontalGroup(
            jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel4Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 599, Short.MAX_VALUE)
                .addContainerGap())
        );
        jPanel4Layout.setVerticalGroup(
            jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel4Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 110, Short.MAX_VALUE)
                .addContainerGap())
        );

        jTabbedPane1.addTab(resourceMap.getString("jPanel4.TabConstraints.tabTitle"), jPanel4); // NOI18N

        jPanel5.setBackground(resourceMap.getColor("jPanel5.background")); // NOI18N
        jPanel5.setBorder(javax.swing.BorderFactory.createEtchedBorder());
        jPanel5.setName("jPanel5"); // NOI18N

        jScrollPane2.setName("jScrollPane2"); // NOI18N

        gradeTipoClientesjTable.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Id#", "Tipo", "Tabela de Preço", "Urgencia", "Bloquear venda"
            }
        ) {
            Class[] types = new Class [] {
                java.lang.Integer.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class
            };
            boolean[] canEdit = new boolean [] {
                false, false, false, false, false
            };

            public Class getColumnClass(int columnIndex) {
                return types [columnIndex];
            }

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        gradeTipoClientesjTable.setFocusable(false);
        gradeTipoClientesjTable.setName("gradeTipoClientesjTable"); // NOI18N
        gradeTipoClientesjTable.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                gradeTipoClientesjTableMouseClicked(evt);
            }
        });
        jScrollPane2.setViewportView(gradeTipoClientesjTable);
        gradeTipoClientesjTable.getColumnModel().getColumn(0).setResizable(false);
        gradeTipoClientesjTable.getColumnModel().getColumn(0).setPreferredWidth(60);
        gradeTipoClientesjTable.getColumnModel().getColumn(0).setHeaderValue(resourceMap.getString("gradeTipoClientesjTable.columnModel.title0")); // NOI18N
        gradeTipoClientesjTable.getColumnModel().getColumn(1).setResizable(false);
        gradeTipoClientesjTable.getColumnModel().getColumn(1).setPreferredWidth(120);
        gradeTipoClientesjTable.getColumnModel().getColumn(1).setHeaderValue(resourceMap.getString("gradeTipoClientesjTable.columnModel.title1")); // NOI18N
        gradeTipoClientesjTable.getColumnModel().getColumn(2).setResizable(false);
        gradeTipoClientesjTable.getColumnModel().getColumn(2).setPreferredWidth(120);
        gradeTipoClientesjTable.getColumnModel().getColumn(2).setHeaderValue(resourceMap.getString("gradeTipoClientesjTable.columnModel.title2")); // NOI18N
        gradeTipoClientesjTable.getColumnModel().getColumn(3).setResizable(false);
        gradeTipoClientesjTable.getColumnModel().getColumn(3).setPreferredWidth(60);
        gradeTipoClientesjTable.getColumnModel().getColumn(3).setHeaderValue(resourceMap.getString("gradeTipoClientesjTable.columnModel.title3")); // NOI18N
        gradeTipoClientesjTable.getColumnModel().getColumn(4).setResizable(false);
        gradeTipoClientesjTable.getColumnModel().getColumn(4).setPreferredWidth(60);
        gradeTipoClientesjTable.getColumnModel().getColumn(4).setHeaderValue(resourceMap.getString("gradeTipoClientesjTable.columnModel.title4")); // NOI18N

        javax.swing.GroupLayout jPanel5Layout = new javax.swing.GroupLayout(jPanel5);
        jPanel5.setLayout(jPanel5Layout);
        jPanel5Layout.setHorizontalGroup(
            jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel5Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 600, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jPanel5Layout.setVerticalGroup(
            jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel5Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 123, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                    .addComponent(jTabbedPane1, javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jPanel5, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()
                .addComponent(jTabbedPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 160, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jPanel5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(jToolBar1, javax.swing.GroupLayout.DEFAULT_SIZE, 644, Short.MAX_VALUE)
            .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addComponent(jToolBar1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

    ClassConecta conexao = new ClassConecta();

    public Color rgb;

    ComboItem combo_tipo_tabela_preco;

    int cod_tipo_cliente;

//***********************************************************************************************************************
    public void getGradeTipoClientes() throws ParseException{
       //Consultar TipoClientes
        TiposClientes oTipoCliente = new TiposClientes();


        if ( tipojTextField.getText().length() > 0 ){
            oTipoCliente.setTipo(tipojTextField.getText()+"%");
        }

        ResultSet resultSet = null;

        String[] colunasTabela = new String[]{"#Id", "Tipo", "Tabela de Preço", "Urgencia", "Bloquear Venda"};
        DefaultTableModel modeloTabela = new DefaultTableModel(null, colunasTabela) {

            @Override
            public boolean isCellEditable(int row, int col) {
                return false;
            }
        };
        gradeTipoClientesjTable.setModel(modeloTabela);
        gradeTipoClientesjTable.getColumnModel().getColumn(0).setPreferredWidth(60);
        gradeTipoClientesjTable.getColumnModel().getColumn(1).setPreferredWidth(120);
        gradeTipoClientesjTable.getColumnModel().getColumn(2).setPreferredWidth(120);
        gradeTipoClientesjTable.getColumnModel().getColumn(3).setPreferredWidth(60);
        gradeTipoClientesjTable.getColumnModel().getColumn(3).setPreferredWidth(60);

        gradeTipoClientesjTable.setDefaultRenderer(Object.class, new ColorRenderer()); // DEIXA A GRADE ZEBRADA



try {


            resultSet = oTipoCliente.getConsultar();

            if (resultSet.getRow() == 1){
             resultSet.first();
            }


        } catch (SQLException ex) {
            Logger.getLogger(TiposClientes.class.getName()).log(Level.SEVERE, null, ex);
        }
        try {

            while (resultSet.next()) {

                modeloTabela.addRow(new String[]{
                    Funcoes.getCodigoFormat(resultSet.getInt("COD_TIPO_CLIENTE")),
                    resultSet.getString("TIPO"),
                    resultSet.getString("TABELA") ,
                    resultSet.getString("URGENCIA"),
                    resultSet.getString("BLOQUEAR_VENDA_INADIMPLENTE"),
                });

            }

        } catch (SQLException ex) {
            Logger.getLogger(TiposClientes.class.getName()).log(Level.SEVERE, null, ex);
        }

           }

    public void getFieldTipoCliente(int codTipoCliente) throws ParseException{

        TiposClientes oTipoCliente = new TiposClientes();
        ResultSet rs = null;
        oTipoCliente.setCod_tipo__cliente(codTipoCliente);

        try {
            rs = oTipoCliente.getConsultar();
            rs.next();

            ComboItem oItem = new ComboItem(rs.getInt("COD_TABELA_PRECO"), rs.getString("TABELA"));
            tipoTabelaPrecojComboBox.setSelectedItem(oItem);

            //Pegar campos
            tipoTabelaPrecojComboBox.setSelectedItem(rs.getString("TABELA"));
            tipojTextField.setText(rs.getString("TIPO"));
            urgenciajComboBox.setSelectedItem(rs.getString("URGENCIA"));
            bloquearVendaInadimplenmtejComboBox.setSelectedItem(rs.getString("BLOQUEAR_VENDA_INADIMPLENTE"));
            tempoMedioAtendimentojTextField.setText(rs.getString("TEMPO_MEDIO_ATENDIMENTO"));
            corjTextField.setText(rs.getString("COR"));

            String cor_rgb = (corjTextField.getText());

            String tar = cor_rgb;
            String [] teste = tar.split(",");


            Color color = new Color(Integer.parseInt(teste[0]),Integer.parseInt(teste[1]),Integer.parseInt(teste[2]));

            painelDeCorjPanel.setBackground(color);



//            painelDeCorjPanel.setBackground(cor_rgb);


        } catch (SQLException ex) {
            Logger.getLogger(TiposClientes.class.getName()).log(Level.SEVERE, null, ex);
        }

    }

    private void formWindowOpened(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_formWindowOpened
        // TODO add your handling code here:
        ClassConecta.conecta();

        salvarjButton.setEnabled(false);
        salvarMaisjButton.setEnabled(false);
        alterarjButton.setEnabled(false);
        excluirjButton.setEnabled(false);
        editarjButton.setEnabled(false);
        novojButton.setEnabled(true);
        tipoTabelaPrecojComboBox.grabFocus();

        atualizaTabelaPrecojButtonActionPerformed(null);
        buscarjButtonActionPerformed(null);
    }//GEN-LAST:event_formWindowOpened

    private void sairjButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_sairjButtonActionPerformed
        // TODO add your handling code here:
        this.dispose();
    }//GEN-LAST:event_sairjButtonActionPerformed

    private void paletaCoresjButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_paletaCoresjButtonActionPerformed
        // TODO add your handling code here:
        Color color = JColorChooser.showDialog(null, "Escolha a cor", Color.WHITE);

        if (color == null){
            color = (Color.WHITE);
        }else{
            painelDeCorjPanel.setBackground(color);
            rgb = color;
            corjTextField.setText(rgb.toString()); // PEGA A COR E TRANSFORMA E MSTRING


            String rgbConvertido = corjTextField.getText().replaceAll("java.awt.Color", "").replace("[", "").replaceAll("r=", "").
                                                           replaceAll("g=", "").replaceAll("b=", "").replace("]", ""); // RETIRA TODOS OS CARACTERES DEIRANCO APENAS A COR RGB
            corjTextField.setText("");
            corjTextField.setText(rgbConvertido);
        }
    }//GEN-LAST:event_paletaCoresjButtonActionPerformed

    private void novojButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_novojButtonActionPerformed
        // TODO add your handling code here:
        novojButton.setEnabled(false);
        alterarjButton.setEnabled(false);
        editarjButton.setEnabled(false);
        excluirjButton.setEnabled(false);
        buscarjButton.setEnabled(true);
        salvarjButton.setEnabled(true);
        salvarMaisjButton.setEnabled(true);
        tipoTabelaPrecojComboBox.grabFocus();
        try {
            ClassConecta.con.setAutoCommit(false);
        } catch (SQLException ex) {
            Logger.getLogger(jFTiposClientes.class.getName()).log(Level.SEVERE, null, ex);
        }
        atualizaTabelaPrecojButtonActionPerformed(null);
        tipojTextField.setText("");
        urgenciajComboBox.setSelectedItem("0 - NORMAL");
        bloquearVendaInadimplenmtejComboBox.setSelectedItem("NÃO");
        tempoMedioAtendimentojTextField.setText("");
        corjTextField.setText("");
        painelDeCorjPanel.setBackground(Color.WHITE);
        descricaojTextArea.setText("");

    }//GEN-LAST:event_novojButtonActionPerformed

    private void atualizaTabelaPrecojButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_atualizaTabelaPrecojButtonActionPerformed
        // TODO add your handling code here:
        try {
            // TODO add your handling code here:
            TabelaPrecos otabelaPreco = new TabelaPrecos();
            ResultSet rs = null;
            rs = otabelaPreco.getConsultar();
            tipoTabelaPrecojComboBox.removeAllItems();
            while (rs.next()) {
                tipoTabelaPrecojComboBox.addItem(new ComboItem(rs.getInt(1), rs.getString(2)));
            }
            tipoTabelaPrecojComboBox.updateUI();
        } catch (SQLException ex) {
            Logger.getLogger(jFPaises.class.getName()).log(Level.SEVERE, null, ex);
        }
    }//GEN-LAST:event_atualizaTabelaPrecojButtonActionPerformed

    private void salvarjButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_salvarjButtonActionPerformed
        // TODO add your handling code here:
            salvarjButton.setEnabled(false);
            salvarMaisjButton.setEnabled(false);
            alterarjButton.setEnabled(false);
            excluirjButton.setEnabled(false);
            novojButton.setEnabled(true);
            editarjButton.setEnabled(true);

            combo_tipo_tabela_preco = (ComboItem) tipoTabelaPrecojComboBox.getSelectedItem();

            TiposClientes oTipoCliente = new TiposClientes();

            if (tipoTabelaPrecojComboBox.getSelectedItem().equals("")){

                JOptionPane.showMessageDialog(null, "Cadastre um tipo de tabela", "ATENÇÃO Mensagem do Sistema", JOptionPane.INFORMATION_MESSAGE);

            }else if (tipojTextField.getText().equals("")){

                JOptionPane.showMessageDialog(null, "O campo ESTADO é obrigatório", "ATENÇÃO Mensagem do Sistema", JOptionPane.INFORMATION_MESSAGE);

            }else{

                oTipoCliente.setCod_tabela_preco(combo_tipo_tabela_preco.getId());
                oTipoCliente.setTipo(tipojTextField.getText().trim().toUpperCase());
                oTipoCliente.setUrgencia(urgenciajComboBox.getSelectedItem().toString());
                oTipoCliente.setBloquear_venda_inadimplente(bloquearVendaInadimplenmtejComboBox.getSelectedItem().toString());
                oTipoCliente.setTempo_medio_atendimento(Float.parseFloat(tempoMedioAtendimentojTextField.getText()));
                oTipoCliente.setCor(corjTextField.getText());
                oTipoCliente.setDescricao(descricaojTextArea.getText());
                oTipoCliente.setCadastrar();
            try {
                ClassConecta.con.commit();
                ClassConecta.con.setAutoCommit(true);
            } catch (SQLException ex) {
                Logger.getLogger(jFTiposClientes.class.getName()).log(Level.SEVERE, null, ex);
            }
            try {
                getGradeTipoClientes();
            } catch (ParseException ex) {
                Logger.getLogger(jFTiposClientes.class.getName()).log(Level.SEVERE, null, ex);
            }


            }
    }//GEN-LAST:event_salvarjButtonActionPerformed

    private void buscarjButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buscarjButtonActionPerformed
        try {
            // TODO add your handling code here:
            getGradeTipoClientes();
        } catch (ParseException ex) {
            Logger.getLogger(jFTiposClientes.class.getName()).log(Level.SEVERE, null, ex);
        }
    }//GEN-LAST:event_buscarjButtonActionPerformed

    private void salvarMaisjButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_salvarMaisjButtonActionPerformed
        // TODO add your handling code here
        salvarjButtonActionPerformed(null);
        novojButtonActionPerformed(null);
    }//GEN-LAST:event_salvarMaisjButtonActionPerformed

    private void gradeTipoClientesjTableMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_gradeTipoClientesjTableMouseClicked
        // TODO add your handling code here:
        editarjButton.setEnabled(true);
            cod_tipo_cliente = Integer.parseInt(gradeTipoClientesjTable.getValueAt(gradeTipoClientesjTable.getSelectedRow(), 0).toString());
            if (cod_tipo_cliente == 0) {
                return;
            }
        try {
            getFieldTipoCliente(cod_tipo_cliente);
        } catch (ParseException ex) {
            Logger.getLogger(jFPaises.class.getName()).log(Level.SEVERE, null, ex);
        }
    }//GEN-LAST:event_gradeTipoClientesjTableMouseClicked

    private void editarjButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editarjButtonActionPerformed
        // TODO add your handling code here:
            novojButton.setEnabled(false);
            salvarjButton.setEnabled(false);
            salvarMaisjButton.setEnabled(false);
            editarjButton.setEnabled(false);
            alterarjButton.setEnabled(true);
            excluirjButton.setEnabled(true);
        try {
            ClassConecta.con.setAutoCommit(false);
        } catch (SQLException ex) {
            Logger.getLogger(jFPessoas.class.getName()).log(Level.SEVERE, null, ex);
        }
    }//GEN-LAST:event_editarjButtonActionPerformed

    private void alterarjButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_alterarjButtonActionPerformed
        // TODO add your handling code here:
        alterarjButton.setEnabled(false);
        editarjButton.setEnabled(true);
        excluirjButton.setEnabled(false);
        novojButton.setEnabled(true);

        combo_tipo_tabela_preco = (ComboItem) tipoTabelaPrecojComboBox.getSelectedItem();

            TiposClientes oTipoCliente = new TiposClientes();

            oTipoCliente.setCod_tipo__cliente(cod_tipo_cliente);

            if (tipoTabelaPrecojComboBox.getSelectedItem().equals("")){

                JOptionPane.showMessageDialog(null, "Cadastre um tipo de tabela", "ATENÇÃO Mensagem do Sistema", JOptionPane.INFORMATION_MESSAGE);

            }else if (tipojTextField.getText().equals("")){

                JOptionPane.showMessageDialog(null, "O campo ESTADO é obrigatório", "ATENÇÃO Mensagem do Sistema", JOptionPane.INFORMATION_MESSAGE);

            }else{

                oTipoCliente.setCod_tabela_preco(combo_tipo_tabela_preco.getId());
                oTipoCliente.setTipo(tipojTextField.getText().trim().toUpperCase());
                oTipoCliente.setUrgencia(urgenciajComboBox.getSelectedItem().toString());
                oTipoCliente.setBloquear_venda_inadimplente(bloquearVendaInadimplenmtejComboBox.getSelectedItem().toString());
                oTipoCliente.setTempo_medio_atendimento(Float.parseFloat(tempoMedioAtendimentojTextField.getText()));
                oTipoCliente.setCor(corjTextField.getText());
                oTipoCliente.setDescricao(descricaojTextArea.getText());
                oTipoCliente.setAlterar(conexao);
            try {
                ClassConecta.con.commit();
                ClassConecta.con.setAutoCommit(true);
            } catch (SQLException ex) {
                Logger.getLogger(jFTiposClientes.class.getName()).log(Level.SEVERE, null, ex);
            }
            try {
                getGradeTipoClientes();
            } catch (ParseException ex) {
                Logger.getLogger(jFTiposClientes.class.getName()).log(Level.SEVERE, null, ex);
            }


            }

    }//GEN-LAST:event_alterarjButtonActionPerformed

    private void excluirjButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_excluirjButtonActionPerformed
        // TODO add your handling code here:
        Object[] options = {"Sim", "Não"};
        int sd =
                JOptionPane.showOptionDialog(null, "Deseja realmente EXCLUIR esse registro?", "Confirmação do Sistema!", JOptionPane.DEFAULT_OPTION,
                JOptionPane.WARNING_MESSAGE, null, options, options[0]);

        if (sd != 0) {
            return;
        }
        alterarjButton.setEnabled(false);
        editarjButton.setEnabled(true);
        excluirjButton.setEnabled(false);
        novojButton.setEnabled(true);

        TiposClientes oTipoCliente = new TiposClientes();
        oTipoCliente.setCod_tipo__cliente(cod_tipo_cliente);

        oTipoCliente.setExcluir(conexao);
        try {
            ClassConecta.con.commit();
            ClassConecta.con.setAutoCommit(true);
        } catch (SQLException ex) {
            Logger.getLogger(jFPaises.class.getName()).log(Level.SEVERE, null, ex);
        }

        atualizaTabelaPrecojButtonActionPerformed(null);
        tipojTextField.setText("");
        urgenciajComboBox.setSelectedItem("0 - NORMAL");
        bloquearVendaInadimplenmtejComboBox.setSelectedItem("NÃO");
        tempoMedioAtendimentojTextField.setText("");
        corjTextField.setText("");
        painelDeCorjPanel.setBackground(Color.WHITE);
        descricaojTextArea.setText("");
        try {
            getGradeTipoClientes();
        } catch (ParseException ex) {
            Logger.getLogger(jFPaises.class.getName()).log(Level.SEVERE, null, ex);
        }
    }//GEN-LAST:event_excluirjButtonActionPerformed

    /**
    * @param args the command line arguments
    */
    public static void main(String args[]) {
        java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
                new jFTiposClientes().setVisible(true);
            }
        });
    }

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton alterarjButton;
    private javax.swing.JButton atualizaTabelaPrecojButton;
    private javax.swing.JComboBox bloquearVendaInadimplenmtejComboBox;
    private javax.swing.JButton buscarjButton;
    private javax.swing.JButton cadastraTipoTabela;
    private javax.swing.JTextField corjTextField;
    private javax.swing.JTextArea descricaojTextArea;
    private javax.swing.JButton editarjButton;
    private javax.swing.JButton excluirjButton;
    private javax.swing.JTable gradeTipoClientesjTable;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JLabel jLabel5;
    private javax.swing.JLabel jLabel6;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JPanel jPanel2;
    private javax.swing.JPanel jPanel4;
    private javax.swing.JPanel jPanel5;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JToolBar.Separator jSeparator1;
    private javax.swing.JToolBar.Separator jSeparator2;
    private javax.swing.JTabbedPane jTabbedPane1;
    private javax.swing.JToolBar jToolBar1;
    private javax.swing.JButton novojButton;
    private javax.swing.JPanel painelDeCorjPanel;
    private javax.swing.JButton paletaCoresjButton;
    private javax.swing.JButton sairjButton;
    private javax.swing.JButton salvarMaisjButton;
    private javax.swing.JButton salvarjButton;
    private javax.swing.JTextField tempoMedioAtendimentojTextField;
    private javax.swing.JComboBox tipoTabelaPrecojComboBox;
    private javax.swing.JTextField tipojTextField;
    private javax.swing.JComboBox urgenciajComboBox;
    // End of variables declaration//GEN-END:variables

}
